<p id="notice"><%= notice %></p>

<h1>Listing Admin Users</h1>

<table>
  <thead>
    <tr>
      <th>Account</th>
      <th>Email</th>
      <th>Is admin</th>
      <th>Name</th>
      <th>Phone</th>
      <th>Study no</th>
      <th colspan="3"></th>
    </tr>
  </thead>

  <tbody>
    <% @admin_users.each do |admin_user| %>
      <tr>
        <td><%= admin_user.account %></td>
        <td><%= admin_user.email %></td>
        <td><%= admin_user.is_admin %></td>
        <td><%= admin_user.name %></td>
        <td><%= admin_user.phone %></td>
        <td><%= admin_user.study_no %></td>
        <td><%= link_to 'Show', admin_user %></td>
        <td><%= link_to 'Edit', edit_admin_user_path(admin_user) %></td>
        <td><%= link_to 'Destroy', admin_user, method: :delete, data: { confirm: 'Are you sure?' } %></td>
      </tr>
    <% end %>
  </tbody>
</table>

<br>

<%= link_to 'New User', new_admin_user_path %>
